<?php
$usersEmail = "blacknaml.laits@gmail.com";
$defaultImage = "http://lorempixel.com/400/200/";
 
// The size of the image
$avatarSize = "50";
// Minimum rating for your site
// Possible values (G, PG, R, X)
$avatarRating = "G";
 
// Border around the image
$avatarBorder = "000000";
 
// URL for Gravatar
$gravatarURL = "http://www.gravatar.com/avatar.php?gravatar_id=%s&default=%s&size=%s&border=%s&rating=%s";
 
$avatarURL = sprintf
(
	$gravatarURL,
	md5($usersEmail),
	$defaultImage,
	$avatarSize,
	$avatarBorder,
	$avatarRating
);
 
echo "<img src='" . $avatarURL . "' width='" .	$avatarSize . "' height='" . $avatarSize . "' />";
?>